#include"vctor.h"

namespace bit
{
	void test1()
	{
		vector<int> v;
		v.push_back(1);
		v.push_back(2);
		v.push_back(3);
		v.push_back(4);
		vector<int>::iterator it = v.begin();
		while (it < v.end())
		{
			cout << *it << " ";
			it++;
		}
		cout << endl;
		//vector<int>::iterator pos = v.insert(find(v.begin(), v.end(), 3), 100); 
		v.insert(find(v.begin(), v.end(), 3), 100);
		for (auto& e : v)
		{
			cout << e << " ";
		}
		cout << endl;
		v.erase(find(v.begin(), v.end(), 3));
		for (auto& e : v)
		{
			cout << e << " ";
		}
		cout << endl;
		vector<int> v1(v);
		for (size_t i = 0; i < v1.size(); i++)
		{
			cout << v1[i] << " ";
		}
		cout << endl;
	}
}

int main()
{
	bit::test1();
	return 0;
}